import Layout from '@/layout/index.vue'

/**
 * hidden: true                  如果设置为 true，该项菜单将不会显示在菜单栏中(默认为 false)
 * meta : {
    title: 'title'               菜单名
    icon: 'icon-name'            图标名
    fixed: true                  如果设置为 true，该项 tag 将一直存在 tag 栏中(默认为 false)
  }
 * */

export const asyncRoutes = [
  {
    path: '/video',
    name: 'VideoData',
    component: Layout,
    redirect: '/video/video',
    meta: {
      title: '在线监控',
      icon: 'vue-dsn-icon-video'
    },
    children: [
      {
        path: 'video',
        name: 'Video',
        component: () => import('@/views/video/video.vue'),
        meta: {
          title: '实时数据'
        }
      },
      {
        path: 'videoWatch',
        name: 'VideoWatch',
        component: () => import('@/views/video/videoWatch.vue'),
        meta: {
          title: '视频监控'
        }
      },
      {
        path: 'videoSet',
        name: 'VideoSet',
        component: () => import('@/views/video/videoSet.vue'),
        meta: {
          title: '继电器控制'
        }
      }
    ]
  },
  {
    path: '/dataCenter',
    name: 'DataCenter',
    component: Layout,
    redirect: '/dataCenter/history',
    meta: {
      title: '数据中心',
      icon: 'vue-dsn-icon-biaoge'
    },
    children: [
      {
        path: 'history',
        name: 'History',
        component: () => import('@/views/dataCenter/history.vue'),
        meta: {
          title: '历史数据'
        }
      },
      {
        path: 'bjData',
        name: 'BjData',
        component: () => import('@/views/dataCenter/bjData.vue'),
        meta: {
          title: '报警数据'
        }
      },
      {
        path: 'czjl',
        name: 'Czjl',
        component: () => import('@/views/dataCenter/czjl.vue'),
        meta: {
          title: '继电器操作记录'
        }
      },
      {
        path: 'tzjl',
        name: 'Tzjl',
        component: () => import('@/views/dataCenter/tzjl.vue'),
        meta: {
          title: '通知记录'
        }
      }
    ]
  },
  {
    path: '/setting',
    name: 'Setting',
    component: Layout,
    redirect: '/setting/userSet',
    meta: {
      title: '系统设置',
      icon: 'el-icon-setting'
    },
    children: [
      {
        path: 'userSet',
        name: 'UserSet',
        component: () => import('@/views/setting/userSet.vue'),
        meta: {
          title: '账号管理'
        }
      },
      {
        path: 'facilities',
        name: 'Facilities',
        component: () => import('@/views/setting/facilities.vue'),
        meta: {
          title: '设备管理'
        }
      },
      {
        path: 'system',
        name: 'System',
        component: () => import('@/views/setting/system.vue'),
        meta: {
          title: '系统日志'
        }
      }
    ]
  }
]
